package com.jgp.timing.model;

import com.jgp.common.persistence.LONGModel;
import lombok.Getter;
import lombok.Setter;
import org.hibernate.annotations.Type;

import javax.persistence.*;

/**
 * 项目   jgp-cloud-parent
 * 作者   loufei
 * 时间   2019/3/25
 */
@Getter
@Setter
@Entity
@Table(name = "sys_timing_job")
public class TimingJob extends LONGModel{
    
    @Column(name = "name",length = 100)
    private String name;
    
    @Column(name = "cron",length = 100)
    private String cron;
    
    @Column(name = "remark")
    private String remark;
    
    @Column(name = "times")
    private Long times;
    
    @Enumerated(EnumType.STRING)
    @Column(name = "type")
    private TaskTargetType type;
    
    @Column(name = "target")
    private String target;
    
    @Type(type = "yes_no")
    @Column(name = "started")
    private Boolean started;
    
    @Column(name = "json_params")
    private String jsonParams;
    
    @Column(name = "thread_id")
    private Long threadId;
    
}
